Package com.cisco.pt.ipc.sim.impl
Class ModuleDescriptorImpl
java.lang.Object
com.cisco.pt.ipc.impl.IPCObjectImpl
com.cisco.pt.ipc.sim.impl.ModuleDescriptorImpl
- All Implemented Interfaces:
IPCObject,ModuleDescriptor
Information provided by the PKI file:
\class ModuleDescriptor
\brief Descriptor for modules. Used to create a module based on the stored information.
- Author:
- Auto-generated
-
Field Summary
Fields inherited from class com.cisco.pt.ipc.impl.IPCObjectImpl
accessMessage, ipcFactory, packetTracerSession -
Constructor Summary
ConstructorsConstructorDescriptionModuleDescriptorImpl(IPCFactory ipcFactory, PacketTracerSession packetTracerSession, IPCMessageLTV accessMessage) -
Method Summary
Modifier and TypeMethodDescriptionaddModulePhysicalView(int X1, int X2, int Y1, int Y2) Information provided by the PKI file:voidaddSlot(ModuleType type) Information provided by the PKI file:create()Information provided by the PKI file:getGroup()Information provided by the PKI file:Information provided by the PKI file:getInfo()Information provided by the PKI file:getModel()Information provided by the PKI file:getModuleAt(int index) Information provided by the PKI file:intInformation provided by the PKI file:getModulePhysicalViewAt(int index) Information provided by the PKI file:intInformation provided by the PKI file:intInformation provided by the PKI file:getSlotTypeAt(int index) Information provided by the PKI file:getType()Information provided by the PKI file:booleanInformation provided by the PKI file:voidremoveModuleAt(int index) Information provided by the PKI file:voidInformation provided by the PKI file:voidsetHotSwappable(boolean bHot) Information provided by the PKI file:voidsetImagePath(String path) Information provided by the PKI file:voidInformation provided by the PKI file:Methods inherited from class com.cisco.pt.ipc.impl.IPCObjectImpl
getAccessMessage, getClassName, getFactory, getObjectUUID, getPacketTracerSession, sendMessage, sendMessageWithReturn, translateToCommandStatusStringPairMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.cisco.pt.ipc.IPCObject
getAccessMessage, getClassName, getFactory, getObjectUUID, getPacketTracerSession
-
Constructor Details
-
ModuleDescriptorImpl
public ModuleDescriptorImpl(IPCFactory ipcFactory, PacketTracerSession packetTracerSession, IPCMessageLTV accessMessage)
-
-
Method Details
-
getType
Information provided by the PKI file:
\brief Returns the type of the module descriptor. \return ModuleType, the number of the module. Types: eLineCard = 0, eNetworkModule = 1, eInterfaceCard = 2, ePtRouterModule = 3, ePtSwitchModule = 4, ePtCloudModule = 5, ePtRepeaterModule = 6, ePtHostModule = 7, ePtModemModule = 8, ePtLaptopModule = 9, ePtTVModule = 10, eIpPhonePowerAdapter = 11, ePtTabletPCModule = 12, ePtPdaModule = 13, ePtWirelessEndDeviceModule = 14, ePtWiredEndDeviceModule = 15, eTrs35 = 16, eUsb = 17, eNonRemovableModule = 18, eASAModule = 19, eASAPowerAdapter = 20, ePtCellTowerModule = 21, ePtIoeModule = 22, ePtIoeNetworkModule = 23, ePtIoeAnalogModule = 24, ePtIoeDigitalModule = 25, ePtIoeCustomIOModule = 26, ePtIoePowerAdapter = 27, ePtIoeMcuComponentPowerAdapter = 28, ePtRouterPowerAdapter = 29, eSfpModule = 30, eAccessPointPowerAdaptor = 31, eNonRemovableInterfaceCard = 32, eCustomModuleType = 2000- Specified by:
getTypein interfaceModuleDescriptor- Returns:
- ModuleType Returns a ModuleType
-
getModel
Information provided by the PKI file:
\brief Returns type name of the module.. \return string, type name of the model. Something like "NM-2W".- Specified by:
getModelin interfaceModuleDescriptor- Returns:
- String Returns a String
-
setImagePath
Information provided by the PKI file:
\brief Sets the image path to the image to use for the module. \param path, path of the image to use. Something like "../art/PhysicalView/gModuleNM-4AS.xpm"- Specified by:
setImagePathin interfaceModuleDescriptor- Parameters:
path- Takes in a parameter of path
-
getImagePath
Information provided by the PKI file:
\brief Gets the image path to the image to use for the module. \return string, path of the image to use. Something like "../art/PhysicalView/gModuleNM-4AS.xpm"- Specified by:
getImagePathin interfaceModuleDescriptor- Returns:
- String Returns a String
-
setInfo
Information provided by the PKI file:
\brief Sets the text to display when in module view and the module is selected. \param strInfo, text to display explaining the module.- Specified by:
setInfoin interfaceModuleDescriptor- Parameters:
strInfo- Takes in a parameter of strInfo
-
getInfo
Information provided by the PKI file:
\brief Gets the text to display when in module view and the module is selected. \return QString, text that is displayed explaining the module.- Specified by:
getInfoin interfaceModuleDescriptor- Returns:
- String Returns a String
-
setGroup
Information provided by the PKI file:
\brief Sets the group the module is considered a part of. \param group, Some modules use this and most don't. The ones that do can be "SENSORS" or "ACTUATORS".- Specified by:
setGroupin interfaceModuleDescriptor- Parameters:
group- Takes in a parameter of group
-
getGroup
Information provided by the PKI file:
\brief Gets the group the module is considered a part of. \return QString, Some modules use this and most don't. The ones that do can be "SENSORS" or "ACTUATORS".- Specified by:
getGroupin interfaceModuleDescriptor- Returns:
- String Returns a String
-
addSlot
Information provided by the PKI file:
\brief Adds the given module type to the module descriptor. Doing this allows the module type to be added to the module created from the descriptor. \param type, module type to add.- Specified by:
addSlotin interfaceModuleDescriptor- Parameters:
type- Takes in a parameter of type
-
getSlotCount
public int getSlotCount()Information provided by the PKI file:
\brief Returns the number of slots in the descriptor. \return int, the number of slots in the descriptor.- Specified by:
getSlotCountin interfaceModuleDescriptor- Returns:
- int Returns a int
-
getSlotTypeAt
Information provided by the PKI file:
\brief Returns the module type of the given slot index. \param index, slot index to get the module type for. \return ModuleType, the module type of the given slot index.- Specified by:
getSlotTypeAtin interfaceModuleDescriptor- Parameters:
index- Takes in a parameter of index- Returns:
- ModuleType Returns a ModuleType
-
removeModuleAt
public void removeModuleAt(int index) Information provided by the PKI file:
\brief Removes the module descriptor to the given module index. \param index, index to try to remove the module descriptor from. Range (0, getModuleCount()-1).- Specified by:
removeModuleAtin interfaceModuleDescriptor- Parameters:
index- Takes in a parameter of index
-
getModuleCount
public int getModuleCount()Information provided by the PKI file:
\brief Returns the number of module descriptions stored. \return int, the number of module descriptions stored.- Specified by:
getModuleCountin interfaceModuleDescriptor- Returns:
- int Returns a int
-
getModuleAt
Information provided by the PKI file:
\brief Returns module description at the given index. \param index, index to retrive the description from. Range (0, getModuleCount()-1). \return ModuleDescriptor, the module description at the given index.- Specified by:
getModuleAtin interfaceModuleDescriptor- Parameters:
index- Takes in a parameter of index- Returns:
- ModuleDescriptor Returns a ModuleDescriptor
-
setHotSwappable
public void setHotSwappable(boolean bHot) Information provided by the PKI file:
\brief Set if the module is hot swappable (able to be removed and added while the device is powered on). \param bHot, true if the module can be added and removed while the device is powered on, false if not.- Specified by:
setHotSwappablein interfaceModuleDescriptor- Parameters:
bHot- Takes in a parameter of bHot
-
isHotSwappable
public boolean isHotSwappable()Information provided by the PKI file:
\brief Get if the module is hot swappable (able to be removed and added while the device is powered on). \return bool, true if the module can be added and removed while the device is powered on, false if not.- Specified by:
isHotSwappablein interfaceModuleDescriptor- Returns:
- boolean Returns a boolean
-
addModulePhysicalView
Information provided by the PKI file:
\brief Add a display area to the descriptor. \param X1, left x. \param X2, right x. \param Y1, top y. \param Y2, bottom y.- Specified by:
addModulePhysicalViewin interfaceModuleDescriptor- Parameters:
X1- Takes in a parameter of X1X2- Takes in a parameter of X2Y1- Takes in a parameter of Y1Y2- Takes in a parameter of Y2- Returns:
- ModulePhysicalView Returns a ModulePhysicalView
-
getModulePhysicalViewCount
public int getModulePhysicalViewCount()Information provided by the PKI file:
\brief Get the number of display areas in the module. \return int, the number of display areas in the module descriptor.- Specified by:
getModulePhysicalViewCountin interfaceModuleDescriptor- Returns:
- int Returns a int
-
getModulePhysicalViewAt
Information provided by the PKI file:
\brief Get the display area at the given index. \param index, index of the display area to retrive. return ModulePhysicalView, display area at the given index.- Specified by:
getModulePhysicalViewAtin interfaceModuleDescriptor- Parameters:
index- Takes in a parameter of index- Returns:
- ModulePhysicalView Returns a ModulePhysicalView
-
create
Information provided by the PKI file:
\brief Create a module using the descriptor. \return Module, module created using the descriptor.- Specified by:
createin interfaceModuleDescriptor- Returns:
- Module Returns a Module
-